package com.zc.designmodel.creative.singleton;

/**
 * @author: zhuCan
 * @date: 2020/4/11 15:22
 * @description: 懒汉单例
 */
public class LazySingleton {

  private static LazySingleton instance;

  private LazySingleton(){}

  public static LazySingleton getInstance(){
    if (instance==null){
      instance=new LazySingleton();
    }
    return instance;
  }
}
